﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Demo6
{
    internal class Program
    {
        static void Main(string[] args)
        {
            // 判断奇偶
            //var num =Convert.ToInt32( Console.ReadLine());
            //if (num % 2 == 0)
            //    Console.WriteLine("{0}是偶数", num);
            //else
            //    Console.WriteLine("{0}是奇数", num);

            //var message = num % 2 == 0 ?num+"是偶数" : num + "是奇数";
            //Console.WriteLine(message);

            var num1 =3;
            var num2 =6;
            var num3 = 2;
            var num4 = 9;
            var num5 = 11;
            //var result =num1>num2 ? num2 : num3>num4 ? num4 : num5;
            var result =num1>num2 ? num2 : (num3>num4 ? num4 : num5);

            Console.WriteLine(result);

            Console.ReadKey();
        }
    }
}
